Skip to content

Conversation

ezhang6811
Copy link
Contributor

@ezhang6811 ezhang6811 commented Sep 23, 2025

Issue #, if available:

Description of changes:
Add a workflow nightly-build.yml with following actions:

  • creates or checks out existing nightly-dependency-updates branch
  • checks for newest versions of dependencies in opentelemetry-python and opentelemetry-python-contrib, bumps versions if applicable, and creates/updates PR
  • search for releases with breaking changes in release notes, and links in the PR
  • runs main build checks on the branch, publishes a failure metric based on the outcome.

Example nightly build PR: #484

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@ezhang6811 ezhang6811 requested a review from a team as a code owner September 23, 2025 01:59
@ezhang6811 ezhang6811 added the skip changelog doesn't need a CHANGELOG entry label Sep 23, 2025
@ezhang6811
Copy link
Contributor Author

I just realized: I updated main build so that it also triggers when pushes are made to the nightly-dependency-updates branch so that updates to the nightly build PR can trigger main build again. If this is the case, do we even need to run main build in the nightly build workflow itself, or is that redundant?

Copy link
Contributor

@thpierce thpierce left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not a complete review, just some initial thoughts.

Comment on lines +43 to +44
with:
ref: ${{ inputs.ref || github.sha }}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why github.sha? Is there no github.ref? Just a bit unclear why this is correct.

needs: [ build, application-signals-e2e-test ]
runs-on: ubuntu-latest
if: always()
if: always() && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/'))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we still need always()? Also release/v I think.

Suggested change
if: always() && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/'))
if: (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/v'))

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How did we confirm that refs/heads/main is correct?

@@ -0,0 +1,147 @@
name: Nightly Upstream Snapshot Build
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lets add a description

- name: Set up Python
uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c #v6.0.0
with:
python-version: '3.11'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why 3.11?

Comment on lines +49 to +50
OTEL_PYTHON_VERSION: ${{ steps.get_versions.outputs.otel_python_version }}
OTEL_CONTRIB_VERSION: ${{ steps.get_versions.outputs.otel_contrib_version }}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting, does that work? I didn't realize a script could send outputs to the GH action like this. Just want to confirm we tested this.


# Check if this release is between current and new version
try:
if version.parse(release_version) > version.parse(current_version) and version.parse(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sanity check: Does this handle patch versions well? Would like to see a bit of testing here, can just be a manual thing.

Comment on lines +54 to +56
if any(
keyword in body for keyword in ["breaking change", "breaking changes", "breaking:", "breaking"]
):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's this based on?

Does this work for [BREAKING], which I saw here?

}
)
except (ValueError, KeyError):
# Skip releases with invalid version formats or missing data
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lets at least log it.

Comment on lines +71 to +73
except requests.RequestException as request_error:
print(f"Warning: Could not get releases for {repo}: {request_error}")
return []
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we fail?

Comment on lines +97 to +98
**Upstream releases with breaking changes:**
${{ steps.breaking_changes.outputs.breaking_changes_info }}"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Elaborate just a bit - callout this is not a perfect system and say what we are looking for.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip changelog doesn't need a CHANGELOG entry
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants